Skip to content

Smoke tests: split compaction test and use debug build#6984

Merged
alexhancock merged 4 commits intomainfrom
jackamadeo/debug-build-for-smoke-tests
Feb 8, 2026
Merged

Smoke tests: split compaction test and use debug build#6984
alexhancock merged 4 commits intomainfrom
jackamadeo/debug-build-for-smoke-tests

Conversation

@jamadeo
Copy link
Collaborator

@jamadeo jamadeo commented Feb 5, 2026

  • use a debug build for the smoke tests
  • split the compaction tests to their own job so they can run concurrently

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR changes the smoke test workflow to use debug builds instead of release builds and splits the compaction tests into a separate job for concurrent execution.

Changes:

  • Modified build process to use cargo build --bin goose (debug) instead of cargo build --release
  • Updated all artifact paths from target/release/goose to target/debug/goose in the workflow
  • Split compaction tests into a standalone compaction-tests job

Comment on lines +70 to +76
cargo build --bin goose

- name: Upload Binary for Smoke Tests
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
with:
name: goose-binary
path: target/release/goose
path: target/debug/goose
Copy link

Copilot AI Feb 5, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The workflow now builds and uploads a debug binary from target/debug/goose, but the test scripts (test_compaction.sh, test_providers.sh, test_subrecipes.sh, test_mcp.sh) all have hardcoded paths to target/release/goose. Since SKIP_BUILD=1 is set, these scripts won't rebuild the binary but will look for it in the wrong location, causing the tests to fail.

The scripts need to be updated to use target/debug instead of target/release, or an environment variable like GOOSE_BIN should be passed to override the default path.

Copilot uses AI. Check for mistakes.
Copilot AI review requested due to automatic review settings February 5, 2026 17:22
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings February 6, 2026 19:39
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 5 comments.


# Add goose binary to PATH so subagents can find it when spawning
export PATH="$SCRIPT_DIR/target/release:$PATH"
export PATH="$SCRIPT_DIR/target/debug:$PATH"
Copy link

Copilot AI Feb 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With SKIP_BUILD set, this hard-codes the debug target dir; if a user (or another workflow) only has a release build available, the script will fail—consider allowing a GOOSE_BIN/GOOSE_TARGET_DIR override or falling back to target/release when target/debug/goose is missing.

Suggested change
export PATH="$SCRIPT_DIR/target/debug:$PATH"
if [ -n "$GOOSE_BIN" ]; then
GOOSE_DIR="$(dirname "$GOOSE_BIN")"
elif [ -n "$GOOSE_TARGET_DIR" ]; then
GOOSE_DIR="$GOOSE_TARGET_DIR"
elif [ -x "$SCRIPT_DIR/target/debug/goose" ]; then
GOOSE_DIR="$SCRIPT_DIR/target/debug"
elif [ -x "$SCRIPT_DIR/target/release/goose" ]; then
GOOSE_DIR="$SCRIPT_DIR/target/release"
else
echo "Error: goose binary not found. Set GOOSE_BIN or GOOSE_TARGET_DIR, or build goose (debug or release)." >&2
exit 1
fi
export PATH="$GOOSE_DIR:$PATH"

Copilot uses AI. Check for mistakes.
echo "Running recipe with parallel subrecipes..."
TMPFILE=$(mktemp)
if (cd "$TESTDIR" && "$SCRIPT_DIR/target/release/goose" run --recipe project_analyzer_parallel.yaml --no-session 2>&1) | tee "$TMPFILE"; then
if (cd "$TESTDIR" && "$SCRIPT_DIR/target/debug/goose" run --recipe project_analyzer_parallel.yaml --no-session 2>&1) | tee "$TMPFILE"; then
Copy link

Copilot AI Feb 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This invocation assumes the binary is always at target/debug/goose; when SKIP_BUILD=1 and only a release build exists locally, the test will error—consider deriving the path from an env var or auto-detecting debug vs release based on what exists.

Copilot uses AI. Check for mistakes.
Comment on lines 249 to +250
export GOOSE_MODEL="$model"
cd "$testdir" && "$SCRIPT_DIR/target/release/goose" run --text "Immediately use the shell tool to run 'ls'. Do not ask for confirmation." --with-builtin "$BUILTINS" 2>&1
cd "$testdir" && "$SCRIPT_DIR/target/debug/goose" run --text "Immediately use the shell tool to run 'ls'. Do not ask for confirmation." --with-builtin "$BUILTINS" 2>&1
Copy link

Copilot AI Feb 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With SKIP_BUILD enabled this assumes target/debug/goose exists; consider supporting a GOOSE_BIN override or falling back to a release binary so local runs don’t unexpectedly break when only a release build is present.

Copilot uses AI. Check for mistakes.
Comment on lines +14 to 15
GOOSE_BIN="$SCRIPT_DIR/target/debug/goose"

Copy link

Copilot AI Feb 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Setting GOOSE_BIN to target/debug/goose makes SKIP_BUILD mode dependent on a debug build being present; consider letting callers override the binary path (or falling back to target/release) to keep the script usable outside CI.

Suggested change
GOOSE_BIN="$SCRIPT_DIR/target/debug/goose"
# Allow callers to override the goose binary, and fall back to common build outputs.
if [ -z "$GOOSE_BIN" ]; then
if [ -x "$SCRIPT_DIR/target/debug/goose" ]; then
GOOSE_BIN="$SCRIPT_DIR/target/debug/goose"
elif [ -x "$SCRIPT_DIR/target/release/goose" ]; then
GOOSE_BIN="$SCRIPT_DIR/target/release/goose"
else
# Preserve previous default even if it does not exist yet.
GOOSE_BIN="$SCRIPT_DIR/target/debug/goose"
fi
fi

Copilot uses AI. Check for mistakes.
Comment on lines 24 to 26
SCRIPT_DIR=$(pwd)
GOOSE_BIN="$SCRIPT_DIR/target/release/goose"
GOOSE_BIN="$SCRIPT_DIR/target/debug/goose"

Copy link

Copilot AI Feb 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hard-coding GOOSE_BIN to target/debug/goose means SKIP_BUILD requires a debug build to exist; consider supporting an env override or auto-detecting debug vs release so developers can reuse an existing release build when running this script locally.

Copilot uses AI. Check for mistakes.
@alexhancock alexhancock added this pull request to the merge queue Feb 8, 2026
@alexhancock
Copy link
Collaborator

Nice! Could be some time-savings

Merged via the queue into main with commit e670f34 Feb 8, 2026
25 checks passed
@alexhancock alexhancock deleted the jackamadeo/debug-build-for-smoke-tests branch February 8, 2026 02:41
tlongwell-block added a commit that referenced this pull request Feb 9, 2026
* origin/main: (55 commits)
  test(mcp): add image tool test and consolidate MCP test fixtures (#7019)
  fix: remove Option from model listing return types, propagate errors (#7074)
  fix: lazy provider creation for goose acp (#7026) (#7066)
  Smoke tests: split compaction test and use debug build (#6984)
  fix(deps): trim bat to resolve RUSTSEC-2024-0320 (#7061)
  feat: expose AGENT_SESSION_ID env var to extension child processes (#7072)
  fix: add XML tool call parsing fallback for Qwen3-coder via Ollama (#6882)
  Remove clippy too_many_lines lint and decompose long functions (#7064)
  refactor: move disable_session_naming into AgentConfig (#7062)
  Add global config switch to disable automatic session naming (#7052)
  docs: add blog post - 8 Things You Didn't Know About Code Mode (#7059)
  fix: ensure animated elements are visible when prefers-reduced-motion is enabled (#7047)
  Show recommended model on failture (#7040)
  feat(ui): add session content search via API (#7050)
  docs: fix img url (#7053)
  Desktop UI for deleting custom providers (#7042)
  Add blog post: How I Used RPI to Build an OpenClaw Alternative (#7051)
  Remove build-dependencies section from Cargo.toml (#6946)
  add /rp-why skill blog post (#6997)
  fix: fix snake_case function names in code_execution instructions (#7035)
  ...

# Conflicts:
#	scripts/test_subrecipes.sh
lifeizhou-ap added a commit that referenced this pull request Feb 9, 2026
* main: (101 commits)
  fix: lazy provider creation for goose acp (#7026) (#7066)
  Smoke tests: split compaction test and use debug build (#6984)
  fix(deps): trim bat to resolve RUSTSEC-2024-0320 (#7061)
  feat: expose AGENT_SESSION_ID env var to extension child processes (#7072)
  fix: add XML tool call parsing fallback for Qwen3-coder via Ollama (#6882)
  Remove clippy too_many_lines lint and decompose long functions (#7064)
  refactor: move disable_session_naming into AgentConfig (#7062)
  Add global config switch to disable automatic session naming (#7052)
  docs: add blog post - 8 Things You Didn't Know About Code Mode (#7059)
  fix: ensure animated elements are visible when prefers-reduced-motion is enabled (#7047)
  Show recommended model on failture (#7040)
  feat(ui): add session content search via API (#7050)
  docs: fix img url (#7053)
  Desktop UI for deleting custom providers (#7042)
  Add blog post: How I Used RPI to Build an OpenClaw Alternative (#7051)
  Remove build-dependencies section from Cargo.toml (#6946)
  add /rp-why skill blog post (#6997)
  fix: fix snake_case function names in code_execution instructions (#7035)
  Document max_turns settings for recipes and subagents (#7044)
  feat: update Groq declarative data with Preview Models (#7023)
  ...
jh-block added a commit that referenced this pull request Feb 9, 2026
* origin/main: (54 commits)
  chore: strip posthog for sessions/models/daily only (#7079)
  tidy: clean up old benchmark and add gym (#7081)
  fix: use command.process_group(0) for CLI providers, not just MCP (#7083)
  added build notify (#6891)
  test(mcp): add image tool test and consolidate MCP test fixtures (#7019)
  fix: remove Option from model listing return types, propagate errors (#7074)
  fix: lazy provider creation for goose acp (#7026) (#7066)
  Smoke tests: split compaction test and use debug build (#6984)
  fix(deps): trim bat to resolve RUSTSEC-2024-0320 (#7061)
  feat: expose AGENT_SESSION_ID env var to extension child processes (#7072)
  fix: add XML tool call parsing fallback for Qwen3-coder via Ollama (#6882)
  Remove clippy too_many_lines lint and decompose long functions (#7064)
  refactor: move disable_session_naming into AgentConfig (#7062)
  Add global config switch to disable automatic session naming (#7052)
  docs: add blog post - 8 Things You Didn't Know About Code Mode (#7059)
  fix: ensure animated elements are visible when prefers-reduced-motion is enabled (#7047)
  Show recommended model on failture (#7040)
  feat(ui): add session content search via API (#7050)
  docs: fix img url (#7053)
  Desktop UI for deleting custom providers (#7042)
  ...
Tyler-Hardin pushed a commit to Tyler-Hardin/goose that referenced this pull request Feb 11, 2026
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Tyler-Hardin pushed a commit to Tyler-Hardin/goose that referenced this pull request Feb 11, 2026
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

Comments